#!/usr/bin/python
# -*- coding: utf-8 -*-

import sys

def main():
    out = True
    for line in sys.stdin:
        if line.startswith("警告:") or line.startswith("重大:"):
            out = True
        elif line.startswith("情報:"):
            out = False
        if out:
            print line.strip()

if __name__ == '__main__':
    main()
